<div class="trace" id="trace_<%= query_id %>_abridged">
<code>
    <% trace[0..(QueryReviewer::CONFIGURATION["stack_trace_lines"] - 1)].compact.each do |c| %>
      <% if c.match(/:.*:/) %>
        <% file = h(c.slice(0..(c.index(":", c.index(":")+1)-1))) %>
        <span><%= file.split("/")[0..-2].join("/") %>/</span><span class="bold"><%= file.split("/").last %></span>
        <br/>
        <span class="indent"><%= h(c.slice((c.index(":", c.index(":")+1)+1)..-1)) %></span><br/>
      <% else %>
          <span><%= h c %></span><br/>
      <% end  %>
    <% end %>
</code>
<a href="javascript: query_review_toggle('trace_<%= query_id %>_abridged'); query_review_toggle('trace_<%= query_id %>_full')" title="show full trace">FULL</a>
</div>

<div class="trace" style="display: none; max-height: 300px; overflow: scroll" id="trace_<%= query_id %>_full">
<code>
	<% full_trace.compact.each do |c| %>
    <% if c.match(/:.*:/) %>
      <% file = h(c.slice(0..(c.index(":", c.index(":")+1)-1))) %>
      <span><%= file.split("/")[0..-2].join("/") %>/</span><span class="bold"><%= file.split("/").last %></span>
      <br/>
      <span class="indent"><%= h(c.slice((c.index(":", c.index(":")+1)+1)..-1)) %></span><br/>
    <% else %>
        <span><%= h c %></span><br/>
    <% end  %>
  <% end %>
</code>
<a href="javascript: query_review_toggle('trace_<%= query_id %>_abridged'); query_review_toggle('trace_<%= query_id %>_full')" title="show short trace">SHORT</a>
</div>